<template>
  <div class="information">
    <el-tabs v-model="activeName" class="tabs" border>
      <el-tab-pane label="会员信息" name="first">
        <!-- 会员基本信息 -->
        <membership-lnformation
          @goFather="showdata"
         @save="save" 
        ></membership-lnformation>
      </el-tab-pane>
      <!-- <el-tab-pane label="常旅客" name="second">
        <Clk
          :MembershipInformationData="MembershipInformation"
        ></Clk>
      </el-tab-pane>
      <el-tab-pane label="联系方式" name="third">
        <Lxfs :MembershipInformationData="MembershipInformation" @save="save"></Lxfs>
      </el-tab-pane> -->
      <el-tab-pane label="邮寄地址" name="a">
        <Dz  ref="dz" :MembershipInformationData="MembershipInformation"></Dz>
      </el-tab-pane>
      <el-tab-pane label="保险记录" name="b">
        <Insurance :MembershipInformationData="MembershipInformation"></Insurance>
      </el-tab-pane>
      <el-tab-pane label="投诉记录" name="c" >
        <Complain :MembershipInformationData="MembershipInformation"></Complain>
      </el-tab-pane>
      <el-tab-pane label="银行卡账号" name="d">
        <Yhk :MembershipInformationData="MembershipInformation"></Yhk>
      </el-tab-pane>
      <!-- <el-tab-pane label="购卡记录" name="e">
         <Paycard :MembershipInformationData="MembershipInformation"></Paycard>
      </el-tab-pane> -->
      <!-- <el-tab-pane label="证件" name="f">
         <Credentials :MembershipInformationData="MembershipInformation"></Credentials>
      </el-tab-pane> -->
      
      <el-tab-pane label="发票" name="h"><Invoice :MembershipInformationData="MembershipInformation"></Invoice></el-tab-pane>
    </el-tabs>
  </div>
</template>

<script>
import Clk from "../jibenxinxi/clk.vue";
import Dz from "../jibenxinxi/dz.vue";
import Lxfs from "../jibenxinxi/lxfs.vue";
import Yhk from "../jibenxinxi/yhk.vue";
import Credentials from "../jibenxinxi/credentials.vue";
import Invoice from "../jibenxinxi/invoice.vue";
import MembershipLnformation from "../jibenxinxi/membershipLnformation.vue";
import Paycard from "../jibenxinxi/paycardjilu.vue";
import Insurance from "../jibenxinxi/insurance.vue";
import Complain from "../jibenxinxi/complain.vue";

export default {
  name: "information",
  data() {
    return {
      
      activeName: "first",
      // 接收组件参数
      MembershipInformation: {},
    };
  },
  props: {},
  components: {
    // 常旅客
    Invoice,
    Clk,
    Dz,
    Lxfs,
    Yhk,
    MembershipLnformation,
    Insurance,
    Complain,
    Paycard,
    Credentials
  },
  methods: {
    showdata(MembershipInformation) {
      this.MembershipInformation = MembershipInformation;
      // 子传递的值
      console.log(this.MembershipInformation);
    },
    // 兄弟传递方法
    save() {
      this.$refs.MembershipLnformation.getqueryCustomer();
      this.$refs.MembershipLnformation.getfrequentTraveler();
    },
    
  
  },
  mounted(){
    this.save()
  }
};
</script>

<style  scoped>
.tabs {
  margin-left: 20px;
  margin-top: 10px;
}
</style>